import 'package:flutter/material.dart';
import 'package:startapp/routes/MyRouter.dart';

void main() {
  runApp(MyApp());
}

//自定义组件
class MyApp extends StatelessWidget {
  @override
  Widget build(BuildContext context) {
    // MaterialApp是根组件
    return MaterialApp(
      debugShowCheckedModeBanner: false,
      onGenerateRoute: MyRouter().routers,
      //defaultRouteName(`/`),
      // initialRoute: '/',
      theme: ThemeData(primaryColor: Colors.blue),
    );
  }
}
